class CreatePrints < ActiveRecord::Migration
  def self.up
    create_table :prints do |t|
      t.integer   :user_id, :null => false
      t.string    :attachment_file_name
      t.string    :attachment_content_type
      t.integer   :attachment_file_size
      t.text      :comment
      t.integer   :pages_bw, :default => 0
      t.integer   :pages_color, :default => 0
      t.integer   :copies, :default => 1
      t.float     :price, :precision => 5, :scale => 2, :default => 0.0
      t.boolean   :duplex, :default => false
      t.integer   :multipage, :default => 1
      t.boolean   :locked, :default => false
      t.boolean   :printed, :default => false
      t.timestamps
    end
  end

  def self.down
    drop_table :prints
  end
end
